/*******************************************************************************
*	Last Update:19 July, 2023													
*																				
* 	This STATA code reproduces the figure 3 of the paper. 
* 	Other figures are provided as is.
* 										
********************************************************************************/

version 14

clear all
set more off

set scheme s1color
set logtype text

cd "" // YOUR WORKING DIRECTORY

********************************************************************************
* Figure 3: Standalone investment by business group prevalence around GQ upgrades
********************************************************************************
use "./data/baselinesample.dta", replace 

keep if baselinesample == 1

reghdfe investment d_4 d_3 d_2 d_1  d1 d2 d3 d4 d5 d6 d7 d8 d9 d10 ///
 d_4_highshare d_3_highshare d_2_highshare d_1_highshare d1_highshare d2_highshare d3_highshare d4_highshare d5_highshare d6_highshare d7_highshare d8_highshare d9_highshare d10_highshare, absorb(firmid nic2digit#fyear highbgs#nic2digit#fyear) vce (clus cityid)
